package com.kingyun.gpsinspection.purificationservice.dao.mapper.iam.adm;


import com.kingyun.gpsinspection.purificationservice.facade.model.iam.adm.Leave;
import com.kingyun.gpsinspection.purificationservice.facade.model.iam.adm.LeaveHistoricProcessInstanceEntity;
import com.kingyun.gpsinspection.purificationservice.facade.model.iam.adm.LeaveTaskEntity;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;

public interface LeaveMapper {
    int deleteByPrimaryKey(String id);

    int insert(Leave record);

    int insertSelective(Leave record);

    Leave selectByPrimaryKey(String id);

    int updateByPrimaryKeySelective(Leave record);

    int updateByPrimaryKey(Leave record);

    int queryMannualDays(@Param("employeeId") String employeeId,@Param("year") String year);


    List<LeaveHistoricProcessInstanceEntity> getRunningProcessinstances(LeaveHistoricProcessInstanceEntity leaveHistoricProcessInstanceEntity);

    int getRunningProcessinstancesCount(LeaveHistoricProcessInstanceEntity leaveHistoricProcessInstanceEntity);


    List<Map<String,Object>> getTodoTask(LeaveTaskEntity leaveTaskEntity);

    int getTodoTaskCount(LeaveTaskEntity leaveTaskEntity);

    int getRunningTypeDays(@Param("employeeId") String employeeId,@Param("type") Integer type);
}